package tij4.concurrent.source;

import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;

public class ExceptoinThread implements Runnable{

    @Override
    public void run() {
        throw new RuntimeException();
    }

    public static void main(String[] args) {
        try {
            ExecutorService executorService = Executors.newCachedThreadPool();
            executorService.execute(new ExceptoinThread());
        }catch (RuntimeException e){
            System.out.println("RuntimeException has been handled!");
        }
    }
}
